/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package windelpdv;

import java.awt.Graphics;
import java.awt.Image;
import javax.swing.ImageIcon;

/**
 *
 * @author Servidor
 */
public class TelaPdvTeste extends javax.swing.JFrame {

    Image im = new ImageIcon ( getClass ( ).getResource ( "/fundo.png" ) ).getImage ( );
    
    /**
     * Creates new form TelaPdvTeste
     */
    public TelaPdvTeste() {
        initComponents();
    }

    /**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        jLabel1 = new javax.swing.JLabel();

        setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
        setTitle("PDV");
        getContentPane().setLayout(null);

        jLabel1.setIcon(new javax.swing.ImageIcon("D:\\Projetos Java\\WindelPDV\\Papel parede\\wallpaper_tech_gray_1.jpg")); // NOI18N
        getContentPane().add(jLabel1);
        jLabel1.setBounds(0, 0, 1376, 768);

        pack();
    }// </editor-fold>//GEN-END:initComponents

      
  
    public void paintComponent ( Graphics g )  
    {  
        //super.paintComponent ( g );  
        int x = ( this.getWidth ( ) - im.getWidth ( null ) ) / 2;  
        int y = ( this.getHeight ( ) - im.getHeight ( null ) ) / 2;  
        g.drawImage ( im , x , y , this );  
    }  
   
    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JLabel jLabel1;
    // End of variables declaration//GEN-END:variables
}
